<table class="tbform">
	<tr>
		<th style="width:100%;">ชื่อบัญชี</th>
		<th style="width:100px;">หน้าบัญชี</th>
		<th style="width:100px;">เดบิต</th>
		<th style="width:100px;">เครดิต</th>
	</tr>
	<?php foreach ($debits as $debit): ?>
	<tr>
		<td class="dr1">
			<?php echo $debit['account_name'] ?>
			<input type="hidden" name="account_id[dr][]" value="<?php echo $debit['account_id'] ?>" />
		</td>
		<td><?php echo $debit['account_code'] ?></td>
		<td><input type="text" name="price[dr][]" value="" class="number" style="width:100px;" /> </td>
		<td></td>
	</tr>
	<?php endforeach; ?>
	<?php foreach ($credits as $credit): ?>
	<tr>
		<td class="cr1">
			<?php echo $credit['account_name'] ?>
			<input type="hidden" name="account_id[cr][]" value="<?php echo $credit['account_id'] ?>" />
		</td>
		<td><?php echo $credit['account_code'] ?></td>
		<td></td>
		<td><input type="text" name="price[cr][]" value="" class="number" style="width:100px;" /> </td>
	</tr>
	<?php endforeach; ?>
	<tr>
		<th id="error"></td>
		<th>รวม</th>
		<th><span></span><input id="debit" type="hidden" name="debit_sum" value=""  class="number" /></th>
		<th><span></span><input type="hidden" name="credit_sum" value=""  class="number" /></th>
	</tr>
</table>
		